Page({

  /**
   * 页面的初始数据
   */
  data: {
    imgUrls: [
      '/images/manage/top-1.jpg',
      '/images/manage/top-2.jpg',
      '/images/manage/top-3.jpg',
    ],
    indicatorDots: false,
    autoplay: false,
    interval: 3000,
    duration: 800,
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
  
  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {
    
  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
    
  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {
    
  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {
    
  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {
    
  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {
    
  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {
    
  },
  buessinessList: function(){
      wx.navigateTo({
        url: '/pages/buessinessList/buessinessList',
      });
  },
  introduceAgentList: function(){
    var that = this;
    var usertype = wx.getStorageSync('usertype');
    usertype = parseInt(usertype);
    if (usertype == "2") {
      wx.navigateTo({
        url: '/pages/introduceAgentList/introduceAgentList',
      });
    } else {
      wx.showToast({
        title: "抱歉，您无权限使用本功能！",
        icon: 'none',
        duration: 2000
      });
    }
  },
  partnerList: function(){
    var that = this;
    var usertype = wx.getStorageSync('usertype');
    usertype = parseInt(usertype);
    if (usertype == "2") {
      wx.navigateTo({
        url: '/pages/queryPartnerList/queryPartnerList',
      });
    } else {
      wx.showToast({
        title: "抱歉，您无权限使用本功能！",
        icon: 'none',
        duration: 2000
      });
    }
  }
})